#include "widget.h"
#include "connection.h"
#include "logindialog.h"
#include <QApplication>
//总共2044行代码

int main(int argc, char *argv[])
{
    QApplication app(argc, argv);

    if(!creatConnection() || !createXml())
    {
        return 0;
    }

    Widget widget;
    LoginDialog loginDialog;

    if(loginDialog.exec() == QDialog::Accepted)
    {
        widget.show();
        return app.exec();
    }
    else
    {
        return 0;
    }

}
